package com.starnet.studentmanagement.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.Max;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;

/**
 * <p>
 * 
 * </p>
 *
 * @author sangeng
 * @since 2022-03-26
 */
@Data
@EqualsAndHashCode(callSuper = false)
public class CourseSelection {

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /**
     * 学生学号
     */
    @NotNull(message = "学号不能为空")
    private Integer sid;

    /**
     * 课程号
     */
    @NotNull(message = "课程号不能为空")
    private String cid;

    /**
     * 分数
     */
    @NotNull(message = "分数不能为空")
    @Max(value = 100,message = "分数不能大于100")
    @Min(value =0,message = "分数不能小于0")
    private Double mark;


}
